package com.byit.shrio.captcha;/**
 * Created by marker on 2018/3/15.
 */

import lombok.Data;
import org.apache.shiro.authc.UsernamePasswordToken;

/**
 * @author marker
 **/
@Data
public class CaptchaUsernamePasswordToken extends UsernamePasswordToken {

    private String captcha;

    public CaptchaUsernamePasswordToken(String username, char[] chars, boolean rememberMe, String host, String captcha) {
        super.setUsername(username);
        super.setHost(host);
        super.setRememberMe(rememberMe);
        super.setPassword(chars);
        this.captcha = captcha;
    }

    public CaptchaUsernamePasswordToken(String username, String password) {
        super.setUsername(username);
        super.setPassword(password.toCharArray());
    }
}
